<?php

class Contrat
{
    /**
     * @var integer
     */
    private $idContrat;
    
    /**
     * @var Client
     */
    private $client;
    
    /**
     * @var integer
     */
    private $delaiLivraison;
    
    function Contrat($id, $client, $delai)
    {
        $this->idContrat = $id;
        $this->client = $client;
        $this->delaiLivraison = $delai;
    }
    
    /**
     * @return integer
     */
    public function getIdContrat()
    {
        return $this->idContrat;
    }
    
    /**
     * @param integer $idContrat
     */
    public function setIdContrat($idContrat)
    {
        $this->idContrat = $idContrat;
    }
    
    /**
     * @return Client
     */
    public function getClient()
    {
        return $this->client;
    }
    
    /**
     * @param Client $client
     */
    public function setClient($client)
    {
        $this->client = $client;
    }
    
    /**
     * @param integer $clientId
     */
    public function setClientByClientId($clientId)
    {
        //TODO: Implement
    }
    
    /**
     * @return integer
     */
    public function getDelaiLivraison()
    {
        return $this->delaiLivraison;
    }
    
    /**
     * @param integer $delaiLivraison
     */
    public function setDelaiLivraison($delaiLivraison)
    {
        $this->delaiLivraison = $delaiLivraison;
    }
    
    /**
     * @return String
     */
    public function getNomClient()
    {
        $client = $this->getClient();
        return $client->getNomClient() .' '. $client->getPrenomClient();
    }
}